package com.foreknow.demo3;

import java.util.Scanner;

/**
 *
 */
public class ArrayDemo3 {
    public static void main(String[] args) {
        double[] dou = new double[3];
        Scanner input = new Scanner(System.in);
        for (int i=0;i<dou.length;i++){
            System.out.println("请输入成绩：");
            dou[i] = input.nextDouble();
        }
        System.out.println("请输入学号：");
        int no = input.nextInt();
        System.out.println(dou[no-1]);


    }
}











